﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace GraphDrawer {
	public partial class ImportNetwork : UserControl {
		public String graphML;

		public ImportNetwork() {
			InitializeComponent();
			
			Description.Text = Resource.ImportNetworkDescription;
			graphML = String.Empty;
		}

		private void Button_Click(object sender, RoutedEventArgs e) {
			OpenFileDialog dialog = new OpenFileDialog();
			dialog.Filter = "XML Files (*.xml)|*.xml|GraphML Files (*.graphml)|*.graphml";
			Nullable<Boolean> result = dialog.ShowDialog();
			if (result.Value == true) {
				graphML = dialog.File.OpenText().ReadToEnd();
				WizardMenu.PopUp.btnOk.IsEnabled = true;
			}
		}
	}
}
